package com.easy.common.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.easy.common.bean.SeckillActivity;
import com.baomidou.mybatisplus.extension.service.IService;

import java.util.List;

/**
* @author BLNYZYKER
* @description 针对表【seckill_activity(秒杀活动配置表)】的数据库操作Service
* @createDate 2025-09-09 10:11:21
*/
public interface SeckillActivityService extends IService<SeckillActivity> {
    SeckillActivity getActivityById(Integer id);//根据id查询秒杀活动

    SeckillActivity getActivityByName(String name);//根据名称查询秒杀活动

    SeckillActivity getActivityByStatus(Integer status);//根据状态查询秒杀活动

    int addActivity(SeckillActivity seckillActivity);//添加秒杀活动

    int updateActivity(SeckillActivity seckillActivity);//修改秒杀活动

    int deleteActivity(Integer id);//删除秒杀活动

    int updateStatus(SeckillActivity seckillActivity);//秒杀活动状态切换

    List<SeckillActivity> getAll(SeckillActivity seckillActivity);//获取所有秒杀活动

    IPage<SeckillActivity> getPage(SeckillActivity seckillActivity, IPage page);//获取分页秒杀活动
}
